package com.bkq.viettravel;

import android.app.Activity;
import android.content.Intent;
import android.os.Bundle;
import android.view.View;
import android.view.View.OnClickListener;
import android.widget.Button;

public class About extends Activity{
	
	Button bntHome, bntFavorite, bntPlan, bntAbout;
	
	public void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.about);
       
        bntHome = (Button) findViewById(R.id.about_Bnt_home);
        bntFavorite = (Button) findViewById(R.id.about_Bnt_favourite);
        bntPlan = (Button) findViewById(R.id.about_Bnt_plan);
        bntAbout = (Button) findViewById(R.id.about_Bnt_info);
        
        bntHome.setOnClickListener(new OnClickListener() {
			
			@Override
			public void onClick(View v) {
				// TODO Auto-generated method stub
				bntHome.setBackgroundDrawable(getApplicationContext().getResources().getDrawable(R.drawable.icon_trangchinh_selected));
				bntAbout.setBackgroundDrawable(getApplicationContext().getResources().getDrawable(R.drawable.icon_thongtin));
				Intent i = new Intent(About.this, VietTravelActivity.class);
				startActivity(i);
			}
		});
        
        bntFavorite.setOnClickListener(new OnClickListener() {
			
			@Override
			public void onClick(View v) {
				// TODO Auto-generated method stub
				bntFavorite.setBackgroundDrawable(getApplicationContext().getResources().getDrawable(R.drawable.icon_uuthich_selected));
				bntAbout.setBackgroundDrawable(getApplicationContext().getResources().getDrawable(R.drawable.icon_thongtin));
				Intent i = new Intent(About.this, FavoritesActivity.class);
				startActivity(i);
			}
		});
        
        bntPlan.setOnClickListener(new OnClickListener() {
			
			@Override
			public void onClick(View v) {
				// TODO Auto-generated method stub
				bntPlan.setBackgroundDrawable(getApplicationContext().getResources().getDrawable(R.drawable.icon_kehoach_selected));
				bntAbout.setBackgroundDrawable(getApplicationContext().getResources().getDrawable(R.drawable.icon_thongtin));
				Intent i = new Intent(About.this, Plan.class);
				startActivity(i);
			}
		});
        
	}
}
